#include<iostream>
using namespace std;
int main()
{
	long long a=1;
	a = 100*3;
	a = a+1;
	cin>>a;
	
	while(a!=1)
	{
		if(a%2==0)
		{
			a=a/2;
		}
		else
		{
			a=a*3+1;
		}
		cout<<"--->";	
		cout<<a;
	}

	
	
	return 0;
} 
	




